<div class="form">
    <?php
    echo $form;
    ?>
</div>
<?php
$this->widget('bootstrap.widgets.TbGridView', array(
    'type' => 'striped bordered condensed',
    'dataProvider' => $dataProvider,
    'ajaxUpdate' => false,
    'columns' => array(
        array(
//            'headerTemplate' => '{item}全选',
            'class' => 'CCheckBoxColumn',
            'name' => 'id',
            'selectableRows' => 2,
            'id' => 'select',
            'htmlOptions' => array(
                'class' => 'span1',
            ),
        ),
        'id',
        array(
            'name' => 'bucket',
            'htmlOptions' => array(
                'class' => 'span2',
            ),
        ),
        array(
            'name' => 'user_id',
            'htmlOptions' => array(
                'class' => 'span1',
            ),
        ),
        'file_name',
        array(
            'name' => 'image_type',
            'value' => '$data->image_type?$data->image_type:\'非图片或非图片空间\'',
            'htmlOptions' => array(
                'class' => 'span2',
            ),
        ),
        array(
            'name' => 'image_width',
            'htmlOptions' => array(
                'class' => 'span2',
            ),
        ),
        array(
            'name' => 'image_height',
            'htmlOptions' => array(
                'class' => 'span2',
            ),
        ),
        array(
            'name' => 'upload_time',
            'value' => 'date("Y-m-d H:i:s",$data->upload_time)',
        ),
        array(
            'class' => 'bootstrap.widgets.TbButtonColumn',
            'template' => '{view} {update} {delete} ',
            'htmlOptions' => array('style' => 'width: 50px'),
//            'headerHtmlOptions' => array(
//                'class' => 'button-column',
//            ),
            'header' => '操作',
            'buttons' => array(
//                '修改' => array(
//                    'label' => '修改',
//                    'icon' => 'icon-tags',
//                ),
                'view' => array(
                    'url' => 'Yii::app()->createUrl("admin/upyunadmin/show", array("id" => $data->id))',
                ),
                'delete' => array(
                    'url' => 'Yii::app()->createUrl("admin/upyunadmin/delete", array("id" => $data->id))',
                ),
                'update' => array(
                    'url' => 'Yii::app()->createUrl("admin/upyunadmin/update", array("id" => $data->id))',
                ),
            ),
        ),
    ),
));

